package com.qf.utils;

import com.github.pagehelper.PageHelper;
import com.qf.entity.Book;
import org.apache.ibatis.session.RowBounds;
import org.apache.ibatis.session.SqlSession;

import java.util.List;

public class GetAllBooks {
    public List<Book> getAllBooks(){
        PageHelper.offsetPage(1, 10);
        List<Book> list = MybatisUtils.getSqlSession().selectList("x.y.selectIf", null, new RowBounds(0, 10));
        return list;
    }
}
